package com.xh.audit.vo.webform;

import com.mybatisflex.core.query.QueryWrapper;
import com.xh.audit.entity.auditdocument.table.AuditDocumentsTableDef;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.NoArgsConstructor;

/**
 * public static class的实现
 */
public class AuditDocumentQuery {

    @NoArgsConstructor
    @EqualsAndHashCode
    @Data
    public static class QueryByProjectid {
        /**
         * 关联的项目id
         */
        private Integer projectId;

        public QueryWrapper queryWrapperBuild() {
            QueryWrapper queryWrapper = QueryWrapper.create()
                    .and(AuditDocumentsTableDef.AUDIT_DOCUMENTS.PROJECT_ID.eq(projectId));
            return queryWrapper;
        }
    }
}
